home *** CD-ROM | disk | FTP | other *** search
/ Sound Fx / Sound Fx.iso / Software / UNZIPED / DWSTK / DWT.H < prev    next >
Encoding:
C/C++ Source or Header  |  1996-10-09  |  2.3 KB  |  100 lines

  1. /******************************************************************************
  2. File:          dwt.h
  3. Version:     2.22
  4. Tab stops: every 2 columns
  5. Project:     DiamondWare's Sound ToolKit
  6. Copyright: 1994-1995 DiamondWare, Ltd.    All rights reserved.
  7. Written:     Keith Weiner and Erik Lorenzen
  8. Purpose:     Contains declarations for the DW Timer module
  9. History:     94/08/24 KW Started
  10.                      95/02/17 EL Finalized for 1.00
  11.                      95/04/12 EL Finalized for 1.02
  12.                      95/06/16 EL Finalized for 1.03
  13.                      95/07/23 EL Finalized for 1.04, no changes
  14.                      95/08/01 EL Finalized for 2.00, added new defines for pmode errors
  15.                                                                                      & calling conventions
  16.                      95/08/29 EL Finalized for 2.10, no changes
  17.                      95/10/27 EL Finalized for 2.20, added #include "dws.h"
  18.                      95/12/07 EL Finalized for 2.21, no changes
  19.                      96/10/11 EL Finalized for 2.22, no changes
  20.  
  21. NB: This code is not compatible with source profilers
  22. ******************************************************************************/
  23.  
  24.  
  25.  
  26. #ifndef dwt_INCLUDE
  27.  
  28.     #define dwt_INCLUDE
  29.  
  30.  
  31.     #include "dws.h"
  32.  
  33.  
  34.     #ifdef __FLAT__
  35.         #define _dws_CALLCON _cdecl
  36.     #else
  37.         #define _dws_CALLCON _far _pascal
  38.     #endif
  39.  
  40.  
  41.  
  42.     /*
  43.      . Below are the timer rates supported by DWT.    Anything in between
  44.      . the listed values will cause the DOS/BIOS clock to tick erratically
  45.      . and is thus not allowed.  Any value higher than 145.6 Hz means
  46.      . you have some very special circumstances; DWT won't fit your needs
  47.      . anyway.
  48.     */
  49.     #define dwt_18_2HZ         0                        /* 18.2 Hz */
  50.     #define dwt_36_4HZ         1                        /* 36.4 Hz */
  51.     #define dwt_72_8HZ         2                        /* 72.8 Hz */
  52.     #define dwt_145_6HZ      3                        /* 145.6 Hz */
  53.  
  54.  
  55.  
  56.     #ifdef __cplusplus
  57.         extern "C" {
  58.     #endif
  59.  
  60.  
  61.  
  62.     /*
  63.      . See #defines, above
  64.     */
  65.     void _dws_CALLCON dwt_Init(word rate);
  66.  
  67.  
  68.     /*
  69.      . If the program has called dwt_Init, it _MUST_ call dwt_Kill before it
  70.      . terminates.
  71.      .
  72.      . NB: Trap critical errors.    Don't let DOS put up the
  73.      .         "Abort, Retry, Fail?" text.    ('sides, it'll destroy your pretty gfx)
  74.     */
  75.     void _dws_CALLCON dwt_Kill(void);
  76.  
  77.  
  78.     /*
  79.      . The following 2 functions affect the timer, but not the music
  80.     */
  81.     void _dws_CALLCON dwt_Pause(void);
  82.  
  83.     void _dws_CALLCON dwt_UnPause(void);
  84.  
  85.  
  86.     /*
  87.      . Number of ticks since Beginning of World
  88.     */
  89.     dword _dws_CALLCON dwt_MasterTick(void);
  90.  
  91.  
  92.  
  93.     #ifdef __cplusplus
  94.         }
  95.     #endif
  96.  
  97.  
  98.  
  99. #endif
  100.